const getTime = () => {
  let message = ''
  const date = new Date()
  const hour = date.getHours()
  if (hour >= 6 && hour < 12) {
    message = '上午好'
  } else if (hour >= 12 && hour < 18) {
    message = '下午好'
  } else if (hour >= 18 && hour < 24) {
    message = '晚上好'
  } else {
    message = '晚安'
  }
  return message
}
export default getTime
